<blockquote class="layui-elem-quote" style="font-size: 14px">师徒带积分规则
</blockquote>


<hr class="layui-bg-gray">
<form class="layui-form" action="" id="network_form">
    <div class="layui-form-item">
        <div class="layui-inline">
            <label class="layui-form-label" style="width: 350px">年度内期满经考核合格出师的，师傅和徒弟各积</label>
            <div class="layui-input-inline" style="width: 120px;">
                <input type="text" name="masterRule.integral" value="${masterRule.integral}" autocomplete="off" class="layui-input" lay-verify="required|number">
            </div>
        </div>
    </div>
    <div class="layui-form-item">
        <div class="layui-inline">
            <label class="layui-form-label" style="width: 350px">年度内同一师傅有多名徒弟的，师傅积分上限为</label>
            <div class="layui-input-inline" style="width: 120px;">
                <input type="text" name="teacherRule.integral" value="${teacherRule.integral}" autocomplete="off" class="layui-input" lay-verify="required|number">
            </div>
        </div>
    </div>

    <div class="layui-form-item">
        <div class="layui-input-block" style="margin-top: 20px;">

            <button class="layui-btn" lay-submit lay-filter="master_form">提交保存</button>
            <button type="reset" class="layui-btn layui-btn-primary">重置</button>
        </div>
    </div>
</form>

<script>
    $(function(){
        initProTechTrain();
    });
    /**
     * 提交
     */
    function initProTechTrain() {
        layui.use(['form'], function(){
            var form = layui.form;

            form.on('submit(master_form)', function(data){
                form.verify();
                $.ajax({
                    type: "POST",
                    url: 'integral/master_add',
                    data: data.field,
                    dataType: "json",
                    success: function(data){
                        Feng.success("保存成功!");
                    }
                });
                return false;
            });
        });
    }

</script>